<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .container{
            width: 300px;
            height: 100px;
            border: 1px solid #000;
            position: relative;
        }
        .box{
            width: 100px;
            height: 100px;
            background-color: skyblue;
            float: left;
        }
        .box1{
            background-color: skyblue;
        }
        .box2{
            background-color: yellow;
            position: absolute;
            top: 50px;
        }
        .box3{
            background-color: orange;
        }
        /* 
        完全脱离文档流，释放原来占据的空间
        他的层级会提升，会覆盖在没有定位的元素的上面
        */
    </style>
</head>
<body>
    <div class="container">
    <div class="box box1">1</div>
    <div class="box box2">2</div>
    <div class="box box3">3</div>
    </div>
</body>
</html>